home *** CD-ROM | disk | FTP | other *** search
- 2 rem ================================
- 3 rem commodares solution #43-4 :
- 4 rem fraction fun
- 5 rem solution by
- 6 rem frank walczer
- 7 rem ================================
- 10 print"[147]the valid numbers are:":print
- 20 for d=100 to 999
- 30 n=d*d : d$=str$(d) : n$=str$(n)
- 40 d$=mid$(d$,2,3) : n$=mid$(n$,2,6) : t$=d$+n$
- 50 if len(t$)<>9 then 120
- 60 for x=1 to 8
- 70 for y=x+1 to 9
- 80 if mid$(t$,x,1)=mid$(t$,y,1) then 120
- 90 next y
- 100 next x
- 110 print" ";d$" * ";d$;" = ";n$
- 120 next d
-